<%@tag import="java.util.HashSet"%>
<%@tag import="java.util.Set"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>

<%@ attribute name="rules" required="true"%>
<%
	Set<String> accsess = (HashSet<String>) request.getSession().getAttribute("currentAccsess");
	
	jspContext.setAttribute("res", false);
	String[] denny = getJspContext().getAttribute("rules").toString().split(","); 
	for (String d : denny) {
		if (accsess.contains(d)) {
		    jspContext.setAttribute("res", true);
		    break;
		}
	}
%>

<c:if test="${res}">
	<jsp:doBody />
</c:if>